<?php
class buycc
{
	public static function findagent()
	{
		$GetAgent=database::LimitQuery('agent',array(
		'select' => 'agent_name,agent_class',
		'condition' => array(
		'enable' => 'Y'
		)
		));
		return $GetAgent;
	}
	public static function GetMaxId($Table,$Column,$Condition)
	{
		$Sql="select max($Column) from $Table where $Condition";
		$Result=database::GetQueryResult($Sql,0);
		foreach($Result as $ShowResult)
		{
			$max="max($Column)";
			$Id=$ShowResult["$max"];
		}
		$IdReturn=$Id;
		return $IdReturn;
	}
}
?>